<%@ page language="java" contentType="text/html;charset=UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core_rt"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>劳动监察管理信息系统</title>
<link href="<%=request.getContextPath()%>/css/reset.css" rel="stylesheet" type="text/css"/>
<link href="<%=request.getContextPath()%>/css/style.css" rel="stylesheet" type="text/css"/>
<script>
function showDH(fuTitle){
	parent.current.document.getElementById("fuTitle").innerHTML = fuTitle;
	parent.current.document.getElementById("title").innerHTML = "";
}
</script>
</head>
<body>
<div id="main">
<c:if test="${messageCount != 0}">您有<font color=red>${messageCount}</font>条未读消息！<a href="<%=request.getContextPath()%>/MessageInfo.do?method=receiveList" onclick="showDH('我的消息')">>>我的消息</a><br/></c:if>
<c:if test="${fileCount != 0}">您有<font color=red>${fileCount}</font>条未读公文！<a href="<%=request.getContextPath()%>/FileInfo.do?method=receiveList" onclick="showDH('我的公文')">>>我的公文</a><br/></c:if>
<div id="mainnews">
 <div id="titlenews">部门新闻</div>
 <ul>
  <c:forEach items="${newsList}" var="newsInfo">
  <li><span class="list"><a href="<%=request.getContextPath()%>/newsQuery.do?method=newsDetail&newsInfoId=${newsInfo.newsInfoId}" target="_blank" title="${newsInfo.newsInfoTitle }">${fn:substring(newsInfo.newsInfoTitle, 0, 12)}</a></span><span class="newsdate">[<fmt:formatDate pattern="yyyy-MM-dd" value="${newsInfo.newsInfoDate}"/>]</span></li>
  </c:forEach>
 </ul>
</div>
<div id="mainnotice">
 <div id="titlenotice">最新通知</div>
 <ul>
  <c:forEach items="${noticeList}" var="notice">
  <li><span class="list"><a href="<%=request.getContextPath()%>/newsQuery.do?method=noticeDetail&noticeInfoId=${notice.noticeInfoId}" target="_blank" title="${notice.noticeInfoTitle}">${notice.noticeInfoTitle}</a></span><span class="newsdate">[<fmt:formatDate pattern="yyyy-MM-dd" value="${notice.noticeInfoDate}"/>]</span></li>
  </c:forEach> 
 </ul>
</div>
</div>
</body>
</html>